/**
* Created by Mkoa
*/
module.exports = function(sequelize, DataTypes) {
    return sequelize.define('member',{
                nickname: {
                        type: DataTypes.STRING(40),
                        allowNull:false,
                        defaultValue:'0',
                        unique:false,
                        comment: '昵称'
                      },
                pic: {
                        type: DataTypes.STRING(255),
                        allowNull:false,
                        defaultValue:'0',
                        unique:false,
                        comment: '头像地址'
                      },
                sex: {
                        type: DataTypes.INTEGER(1),
                        allowNull:false,
                        defaultValue:'0',
                        unique:false,
                        comment: '性别'
                      },
                type: {
                        type: DataTypes.INTEGER(1),
                        allowNull:false,
                        defaultValue:'0',
                        unique:false,
                        comment: '类型【1:学生 2：老师】'
                      },
                name: {
                        type: DataTypes.STRING(20),
                        allowNull:false,
                        defaultValue:'0',
                        unique:false,
                        comment: '真实姓名'
                      },
                openid: {
                        type: DataTypes.STRING(255),
                        allowNull:false,
                        defaultValue:'0',
                        unique:false,
                        comment: '微信标识'
                      }}, {
        tableName:'mkoa_member',
        comment: '会员表',
        timestamps:true,
        indexes:[],
        paranoid:false,
        charset: 'utf8',
        collate: 'utf8_general_ci'
    });
};